<%@page language="java" contentType="text/html; charset=ISO-8859-1"
	pageEncoding="ISO-8859-1"%>

<%@taglib prefix="jstl" uri="http://java.sun.com/jsp/jstl/core"%>
<%@taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<%@taglib prefix="form" uri="http://www.springframework.org/tags/form"%>
<%@taglib prefix="security"
	uri="http://www.springframework.org/security/tags"%>
<%@taglib prefix="display" uri="http://displaytag.sf.net"%>
<%@taglib prefix="acme" tagdir="/WEB-INF/tags"%>

<form:form action="${requestURI}" modelAttribute="pago">

	<form:hidden path="id" />
	<form:hidden path="version" />
	<form:hidden path="comunidadDeVecinos" />
	<security:authorize access="hasRole('ADMINISTRADOR')">


		<jstl:if test="${!isNew}">
			<acme:textbox code="pago.fecha" path="fecha" readonly="true" />
			<acme:textarea code="pago.razon" path="razonSocial" readonly="true" />
			<acme:textbox code="pago.importe" path="importe" readonly="true" />
			<acme:textbox code="pago.estado" path="estado" readonly="true" />
			<jstl:if test="${pago.estado=='No pagado'}">
				<acme:cancel code="pago.pagar"
					url="/pago/administrator/pagar.do?pagoId=${pago.id}" />
			</jstl:if>

		</jstl:if>

		<jstl:if test="${isNew}">
			<acme:textbox code="pago.fecha" path="fecha" readonly="true" />
			<acme:textarea code="pago.razon" path="razonSocial" />
			<acme:textbox code="pago.importe" path="importe" />
			<acme:textbox code="pago.estado" path="estado" readonly="true" />
			<acme:submit code="pago.create" name="save" />

		</jstl:if>

	</security:authorize>



	<acme:cancel code="pago.goBack" url="${backURI}" />
</form:form>

